1. Field of the Invention
The present invention relates to the field of data processing, and more particularly, to providing background processing for PCMCIA Card Services operating under the Microsoft.TM. Windows v. 3.1 operating system environment.
2. Art Background
Laptop and notebook sized personal computers have become very common. In many existing laptop and notebook sized personal computers, it is difficult to add peripherals because there are no internal expansion slots. Peripherals can be connected to external ports on laptop and notebook sized personal computers. However, the external peripherals hang off the side of the portable computer system thereby making the system no longer portable.
To provide a convenient interface for small peripheral devices, a computer industry consortium drafted a specification defining a standard interface for credit-card sized peripherals. The computer industry consortium is known as the Personal Computer Memory Card Industry Association (PCMCIA) and the standard credit-card sized peripherals are known as PCMCIA Cards. The first version of the PCMCIA specification (PCMCIA 1.0) created an interface that could handle memory card expansion as well as some simple peripherals such as card-sized modems. The second version of the PCMCIA specification (PCMCIA 2.0) is a full bus specification capable of handling most common types of computer peripherals such as hard disk drives and LAN interfaces. (See PC Card Standard, Release 2.0, September 1991, Personal Computer Memory Card International Association)
The PCMCIA standard is defined such that it is possible to plug in and remove cards while the base system is running, without damage to the cards or to the base system. This hot insertion/removal feature is unique to PCMCIA computer hardware. Furthermore, configuration information is kept in memory on a PCMCIA card itself, to allow the system to adapt to the card when it is plugged into a computer system. The PCMCIA standard defines the physical size and shape of PCMCIA cards. The PCMCIA standard also defines power and voltage levels and connector pinouts. Cards which comply with the PCMCIA standard may be plugged into compatible systems without fear that the connectors won't match or that voltage differences will damage the hardware. The standard also defines the range of configuration information which may be kept on the cards, and indicates how software can read this information.
The PCMCIA hardware includes the socket into which the card is plugged, a connector for conveying power and information between the cards and the computer, and a socket adapter integrated circuit which couples the computer microprocessor to the sockets. The adapter contains hardware to generate microprocessor interrupts when a card hardware change event occurs, such as a cards being inserted or removed, or a card battery running low. Mapping hardware allows the card's memory, I/O, and interrupt to be directed to the proper places within the overall computer system. For example, if a card contains memory, the memory may be made to appear at any point in the computer's address space below 16 megabytes. Similarly, if a card can generate an interrupt request, the interrupt request can be routed to one of a number of system IRQ lines.
The Microsoft.TM. Windows operating environment is largely replacing the older DOS only environment in personal computers. The Microsoft.TM. Windows environment provides an attractive graphical user interface (GUI) which makes application programs easier to use. Currently, Windows application programs which require access to Card Services must use the existing real mode implementations of Socket Services and Card Services as device drivers or Terminate and Stay Resident (TSR) programs for DOS. This solution is not very attractive since the system must switch from protected mode, which is used to run Windows applications, into real mode in order to call the Card Services TSR.
In the prior art DOS real mode implementations of Card Services, the background processing is done by the Card Services TSR. The Card Services TSR sets-up a background processing operation and returns to the DOS application or the device driver that called the Card Services TSR. The Card Services TSR gains control of computer system resources only during a limited time based on the system clock ticks. When the time apportioned for background processing based on the clock ticks occurs, the Card Services TSR performs the necessary background processing. Although the DOS background processing using the clock ticks provides satisfactory performance in DOS, it does not provide sufficient performance when running Windows in enhanced mode. For example, when running the Windows enhanced mode, the clock ticks that permit background processing are unreliable and often do not occur frequently enough. Because the use of clock ticks is unreliable when running Windows in enhanced mode, background processing in accordance with the PCMCIA Card Services specification when running Windows in enhanced mode requires an alternative solution. The present invention provides an apparatus and methods for reliable background processing when running Windows in enhanced mode in accordance with the PCMCIA Card Services specification.